{include file="public/header" select="0" /}
<style>
    .bankList input {
        border: none;
        background-color: transparent;
    }
</style>
<body>
<div class="header">
    <i class="layui-icon layui-icon-left" onclick="goBack()"></i> 绑定{$title}
</div>
<form action="{:url('user/method_save',['type'=>$type])}" method="post" class="form layui-form">
<input type="hidden" name="go_back" value="{$Request.param.go_back}"/>
{if $type == 'bank'}
<ul class="upd-phone-list">
    <li class="bankList">
        <p>银行名称</p>
        <select name="bank_name" lay-verify="required" lay-reqtext="请选择银行">
            <option value="">请选择</option>
            {foreach name="bank_list" item="vo"}
            <option value="{$vo.title}" {if $user.bank_name == $vo.title}selected{/if}>{$vo.title}</option>
            {/foreach}
        </select>
    </li>
    <li>
        <p>开户姓名</p>
        <input type="text" name="bank_account_name" lay-verify="required" lay-reqtext="请输入开户姓名"
               placeholder="请输入开户姓名" value="{$user.bank_account_name}" autocomplete="off">
    </li>
    <li>
        <p>银行卡号</p>
        <input type="number" name="bank_number" lay-verify="required" lay-reqtext="请输入银行卡号"
               placeholder="请输入银行卡号" value="{$user.bank_number}" autocomplete="off">
    </li>
    <li>
        <p>开户行地址</p>
        <input type="text" name="bank_open" lay-verify="required" lay-reqtext="请输入开户行地址"
               placeholder="请输入开户行地址" value="{$user.bank_open}" autocomplete="off">
    </li>
</ul>
{else}
<ul class="upd-phone-list">
    <li>
        <p>真实姓名</p>
        <input type="text" name="name" lay-verify="required" lay-reqtext="请输入真实姓名"
               placeholder="请输入真实姓名" value="<?php echo $user[$type . '_name']?>" autocomplete="off">
    </li>
    <li class="upd-label">
        <p>{$title}收款码</p>
        <p class="flex-center" id="uploads_image">
            <img src="<?php echo $user[$type . '_image'];?>" onerror="this.src='/static/index/img/icon15.png'"  alt="" id="image_show">
            <input type="hidden" name="image" id="images_value" value="<?php echo $user[$type . '_image'];?>"/>
        </p>
    </li>
</ul>
{/if}
<p class="save upd-save" lay-submit lay-filter="save" formObj=".form">保存</p>
</form>
{include file="public/footer" select="0" /}
</body>
</html>